#include<iostream>
#include<cstring>
#include<string>
using namespace std;
int main(){
	char s[85];
	gets(s);
	string ss=s;
	for(string::iterator it=ss.begin();it!=ss.end();){
		if(!(*it>='A'&&*it<='Z'||*it>='a'&&*it<='z')){
			it=ss.erase(it);
		}else{
			it++;
		}
	}
	for(int i=0;i<ss.size();i++){
		cout<<ss[i];
	}
	cout<<endl;
	return 0;
}
